/**
 * Created by Administrator on 2017/7/19.
 */

$(function() {
    $("#insert").validate({
        rules: {
            username: {
                required: true,
                minlength: 5,
                maxlength: 11

            },
            password: {
                required: true,
                minlength: 5,
                maxlength: 11

            },
            mobile:{
                required: true,
                minlength: 11,
                maxlength: 11,
                digits:true
            },
            home_phone:{
                minlength: 11,
                maxlength: 11,
                digits:true
            },
            power:{
                required: true,
                minlength: 1,
                maxlength: 1,
                digits:true
            }
        },
        messages: {
            username: {
                remote: "用户名已注册"
            },
            password: {
                required:"这是必须输入的额"
            },
            password_on: {}
        }
    });

});